package com.hlf.modules.merchant.store.service;



import com.hlf.common.utils.PageUtils;
import com.hlf.common.utils.ReturnResult;
import com.hlf.modules.merchant.store.entity.Store;
import com.hlf.modules.sys.entity.SysUserEntity;

import java.util.List;
import java.util.Map;

/***
 * 门店管理
 * @author Administrator
 *
 */
public interface StoreService {

	/**
	 * 查询单个店铺
	 * @param id
	 * @return
	 */
	Store queryObject(Long id);
	
	List<Store> queryList(Map<String, Object> map);
	
	int queryTotal(Map<String, Object> map);

	void update(Store store);

	void save(Store store);
	
	void delete(Long id);
	
	void deleteBatch(Long[] ids);
	
	PageUtils queryListForPage(Map<String, Object> map);

    Store queryObjectForUserId(Long userId);

    String saveStore(Store store);

	/**
	 * 创建门店
	 * @param merchantId
	 * @param storeName
	 * @param bizTypeId
	 * @param province
	 * @param city
	 * @param district
	 * @param address
	 * @param cellphone
	 * @param logoImgFilesJson
	 * @return
	 */
    ReturnResult createStore(String merchantId, String storeName, String bizTypeId, String province, String city,
							 String district, String address, String cellphone, String logoImgFilesJson);

	/**
	 * 门店列表
	 * @param
	 * @return
	 */
    List<Store> queryListForMerchantId(Long merchantId);

	/**
	 * 修改门店信息
	 * @param user
	 * @param name
	 * @param province
	 * @param city
	 * @param district
	 * @param address
	 */
    void updateInfo(SysUserEntity user, String name, String province, String city, String district, String address);

	/**
	 * 上传门店形象照片
	 * @param user
	 * @param storeImgFilesJson
	 */
	void uploadStore(SysUserEntity user, String storeImgFilesJson);

	/**
	 * 保存门店认证信息
	 * @param user
	 * @param merchantName
	 * @param legalPerson
	 * @param identityCardImgJson
	 * @param businessImg
	 * @param qsImg
	 * @param license
	 * @param accountName
	 * @param province
	 * @param city
	 * @param district
	 * @param bankName
	 * @param branchBankName
	 * @param cardNo
	 */
    void saveStoreDetail(SysUserEntity user, String merchantName, String legalPerson, String identityCardImgJson,
						 String businessImg, String qsImg, String license, String accountName, String province, String city,
						 String district, String bankName, String branchBankName, String cardNo , String branchBankId,
						 String type, String openAccountLicenseImg);

	/**
	 * 门店形象
	 * @param user
	 * @return
	 */
	ReturnResult storeImg(SysUserEntity user);
}
